<!DOCTYPE html >
<html xmlns:th="http://www.thymeleaf.org" >
	<head>
		<meta charset="UTF-8">
		<title>uploadwindow</title>
		<meta http-equiv="X-UA-Compatible" content="IE=edge" />
		<meta http-equiv="content-type" content="text/html; charset=utf-8" />
		<link href="../static/resources/css/axure_rp_page.css" type="text/css" rel="stylesheet" />
		<link href="../static/data/styles.css" type="text/css" rel="stylesheet" />
		<link href="../static/files/uploadwindow/styles.css" type="text/css" rel="stylesheet" />
		<link href="http://cdn.bootcss.com/font-awesome/4.7.0/css/font-awesome.css" type="text/css" rel="stylesheet" />
		<script src="../static/resources/scripts/jquery-3.2.1.min.js"></script>
		<script src="../static/resources/scripts/axure/axQuery.js"></script>
		<script src="../static/resources/scripts/axure/globals.js"></script>
		<script src="../static/resources/scripts/axutils.js"></script>
		<script src="../static/resources/scripts/axure/annotation.js"></script>
		<script src="../static/resources/scripts/axure/axQuery.std.js"></script>
		<script src="../static/resources/scripts/axure/doc.js"></script>
		<script src="../static/resources/scripts/messagecenter.js"></script>
		<script src="../static/resources/scripts/axure/events.js"></script>
		<script src="../static/resources/scripts/axure/recording.js"></script>
		<script src="../static/resources/scripts/axure/action.js"></script>
		<script src="../static/resources/scripts/axure/expr.js"></script>
		<script src="../static/resources/scripts/axure/geometry.js"></script>
		<script src="../static/resources/scripts/axure/flyout.js"></script>
		<script src="../static/resources/scripts/axure/model.js"></script>
		<script src="../static/resources/scripts/axure/repeater.js"></script>
		<script src="../static/resources/scripts/axure/sto.js"></script>
		<script src="../static/resources/scripts/axure/utils.temp.js"></script>
		<script src="../static/resources/scripts/axure/variables.js"></script>
		<script src="../static/resources/scripts/axure/drag.js"></script>
		<script src="../static/resources/scripts/axure/move.js"></script>
		<script src="../static/resources/scripts/axure/visibility.js"></script>
		<script src="../static/resources/scripts/axure/style.js"></script>
		<script src="../static/resources/scripts/axure/adaptive.js"></script>
		<script src="../static/resources/scripts/axure/tree.js"></script>
		<script src="../static/resources/scripts/axure/init.temp.js"></script>
		<script src="../static/resources/scripts/axure/legacy.js"></script>
		<script src="../static/resources/scripts/axure/viewer.js"></script>
		<script src="../static/resources/scripts/axure/math.js"></script>
		<script src="../static/resources/scripts/axure/jquery.nicescroll.min.js"></script>
		<script src="../static/data/document.js"></script>
		<script src="../static/files/uploadwindow/data.js"></script>

		<script type="text/javascript">
			$axure.utils.getTransparentGifPath = function() {
				return '../static/resources/../static/images/transparent.gif';
			};
			$axure.utils.getOtherPath = function() {
				return '../static/resources/Other.html';
			};
			$axure.utils.getReloadPath = function() {
				return '../static/resources/reload.html';
			};


			function ProcessFile(e) {

				var file = document.getElementById('file').files[0];
				if (file) {

					var reader = new FileReader();

					reader.onload = function(event) {
						var txt = event.target.result;
						var img = document.createElement("img");
						img.src = txt; //将图片base64字符串赋值给img的src
						img.style.height = '150px';
						img.style.width = '200px';
						img.style.zIndex = '10';
						// console.log(txt);

						document.getElementById("result").appendChild(img);

					};

				}

				reader.readAsDataURL(file);

			}


			function contentLoaded() {

				document.getElementById('file').addEventListener('change',

					ProcessFile, false);

			}


			window.addEventListener("DOMContentLoaded", contentLoaded, false);
		</script>
	</head>
	<body>
		<script type="text/javascript" th:inline="javascript">
			function addEvent(obj, evt, fn) {
				var saved;
				if (typeof obj["on" + evt] == "function") {
					saved = obj["on" + evt];
				}
				obj["on" + evt] = function() {
					if (saved) saved();
					fn();
				}
			}

			function f1() {
				var name = localStorage.getItem("username");
				if (name != null) {
					document.getElementById("ruserid").value = name;
				}
			}
			addEvent(window, 'load', f1);
		</script>
		<div id="base" class="">

			<!-- Unnamed (组合) -->
			<div id="u1355" class="ax_default" data-left="49" data-top="110" data-width="1181" data-height="950">

				<!-- Unnamed (矩形) -->
				<div id="u1356" class="ax_default _默认样式">
					<div id="u1356_div" class=""></div>
					<div id="u1356_text" class="text " style="display:none; visibility: hidden">
						<p></p>
					</div>
				</div>
			</div>

			<!-- Unnamed (矩形) -->
			<div id="u1357" class="ax_default _默认样式">
				<div id="u1357_div" class=""></div>
				<div id="u1357_text" class="text ">
					<p style="font-size:16px;"><span
							style="font-size:14px;text-decoration:none;color:#FFC9A6;">▋</span><span
							style="text-decoration:none;"> 发布共享</span></p>
				</div>
			</div>

			<!-- Unnamed (精简底部) -->

			<!-- Unnamed (精简底部) -->

			<!-- Unnamed (矩形) -->
			<div id="u1360" class="ax_default _默认样式">
				<img id="u1360_img" class="img " src="../static/images/registration/u976.svg" />
				<div id="u1360_text" class="text ">
					<p><span style="text-decoration:none;">Copyright © Enjoy the way All Rights Reserved.</span></p>
					<p><span style="text-decoration:none;">分享好物尽在享道</span></p>
				</div>
			</div>
			<div id="u1359" style="display:none; visibility:hidden;"></div>
			<div id="u1358" style="display:none; visibility:hidden;"></div>

			<!-- 实名认证 (动态面板) -->
			<form th:action="@{/addProduct}" method="post" enctype="multipart/form-data">


				<div id="u1361" class="ax_default" data-label="实名认证">
					<div id="u1361_state0" class="panel_state" data-label="1.提交资料" style="">
						<div id="u1361_state0_content" class="panel_state_content">

							<!-- Unnamed (矩形) -->
							<div id="u1362" class="ax_default _默认样式">
								<div id="u1362_div" class=""></div>
								<div id="u1362_text" class="text ">
									<p><span style="text-decoration:none;">物品名称:</span></p>
								</div>
							</div>

							<!-- Unnamed (文本框(单行)) -->
							<div id="u1363" class="ax_default _默认样式">
								<div id="u1363_div" class=""></div>
								<input id="u1363_input" name="rname" type="text" value="" class="u1363_input"
									maxlength="20" />
							</div>
							<p id="pn"></p>
							<script>
								// 量词是设定某个模式出现的次数
								// 这个模式用户只能输入英文字母 数字 下划线 短横线但是有边界符和[] 这就限定了只能多选1
								var regexp = /^[+]?((\d*(\.\d{1,})$)|(\d+$))/; /*{6,16}  中间不要有空格*/
								var u1363_input = document.querySelector('.u1363_input');
								u1363_input.onblur = function() {
									if (this.value==null||this.value=="") {
										localStorage.setItem("boolean",false);
										document.getElementById('u1375_div').type="button";
										console.log('空的');
										document.getElementById('pn').className = 'right';
										document.getElementById('pn').innerHTML = '物品名称不能为空';
									}else{
										localStorage.setItem("boolean",true);
										document.getElementById('u1375_div').type="submit";
										if(localStorage.getItem("boolean1")=="false"){
											document.getElementById('u1375_div').type="button";
										}
										document.getElementById('pn').innerHTML='';
									}
								}
							</script>
							<!-- Unnamed (矩形) -->
							<div id="u1364" class="ax_default _默认样式">
								<div id="u1364_div" class=""></div>
								<div id="u1364_text" class="text " style="display:none; visibility: hidden">
									<p></p>
								</div>
							</div>

							<!-- Unnamed (矩形) -->
							<div id="u1365" class="ax_default _默认样式">
								<div id="u1365_div" class=""></div>
								<div id="u1365_text" class="text ">
									<p><span style="text-decoration:none;">共享价格:</span></p>
								</div>
							</div>

							<!-- Unnamed (文本框(单行)) -->
							<div id="u1366" class="ax_default _默认样式">
								<div id="u1366_div" class=""></div>
								<input id="u1366_input" name="rprice" type="text" value="" class="u1366_input"
									maxlength="20" />
							</div>
							<p id="pr"></p>
							<script>
								// 量词是设定某个模式出现的次数
								// 这个模式用户只能输入英文字母 数字 下划线 短横线但是有边界符和[] 这就限定了只能多选1
								var regexp = /^[+]?((\d*(\.\d{1,})$)|(\d+$))/; /*{6,16}  中间不要有空格*/
								var u1366_input = document.querySelector('.u1366_input');
								u1366_input.onblur = function() {
									if (regexp.test(this.value)) {
										localStorage.setItem("boolean1",true);
										document.getElementById('u1375_div').type="submit";
										if(localStorage.getItem("boolean")=="false"){
											document.getElementById('u1375_div').type="button";
										}
										console.log('正确的');
										document.getElementById('pr').className = 'right';
										document.getElementById('pr').innerHTML = '';
									} else {
										localStorage.setItem("boolean1",false);
										document.getElementById('u1375_div').type="button";
										console.log('错误的');
										document.getElementById('pr').className = 'wrong';
										document.getElementById('pr').innerHTML = '价格码格式输入不正确';
									}
									
								}
							</script>
							<!-- Unnamed (矩形) -->
							<div id="u1367" class="ax_default _默认样式">
								<div id="u1367_div" class=""></div>
								<div id="u1367_text" class="text ">
									<p><span style="text-decoration:none;">物品照片:</span></p>
								</div>
							</div>

							<!-- Unnamed (矩形) -->
							<div id="u1368" class="ax_default _默认样式">
								<div id="u1368_div" class=""></div>
								<div id="u1368_text" class="text ">
									<p><span style="text-decoration:none;">注意事项:</span></p>
								</div>
							</div>

							<!-- Unnamed (矩形) -->
							<div id="u1369" class="ax_default _默认样式">
								<div id="u1369_div" class=""></div>
								<div id="u1369_text" class="text ">
									<p><span style="text-decoration:none;"><br></span></p>
									<p><span style="text-decoration:none;">1、上传图片文件格式支持png，jpg和bmp；</span></p>
									<p><span style="text-decoration:none;">2、单张图片大小不超过3MB，尺寸最小为500px * 500px；</span></p>
									<p><span style="text-decoration:none;"><br></span></p>
								</div>
							</div>
							<div id="wuping_12">
								
							</div>
							<!-- 照片墙上传 (动态面板) -->
							<div id="u1370" class="ax_default" data-label="照片墙上传">
								<div id="u1370_state0" class="panel_state" data-label="默认状态" style="">
									<div id="u1370_state0_content" class="panel_state_content">

										<!-- Unnamed (矩形) -->
										<div id="result" class="">
										</div>

									</div>
								</div>

							</div>

							<input type="file" id="file" name="file">
							<!-- Unnamed (矩形) -->
							<div id="u1375" class="ax_default _默认样式">

								<div id="u1375_text" class="text ">
									<p><span style="text-decoration:none;"><button id="u1375_div" style="text-decoration:none;"
												type="submit" name="add" >确认发布</button></span></p>
								</div>
							</div>
							<!-- 文本域 (文本框(多行)) -->
							<div id="u1386" class="ax_default _默认样式" data-label="文本域">
								<div id="u1386_div" class=""></div>
								<textarea id="u1386_input" name="rdetails" class="u1386_input"></textarea>
							</div>
							<input id="ruserid" name="ruserid" style="display: none"></input>
							<!-- Unnamed (矩形) -->
							<div id="u1387" class="ax_default _默认样式">
								<div id="u1387_div" class=""></div>
								<div id="u1387_text" class="text ">
									<p><span style="text-decoration:none;">物品详情:</span></p>
								</div>
							</div>
						</div>
					</div>
				</div>
			</form>



			<!-- Unnamed (精简顶部) -->

			<!-- 顶部背景 (动态面板) -->
			<div id="u1392" class="ax_default" data-label="顶部背景">
				<div id="u1392_state0" class="panel_state" data-label="State1" style="">
					<div id="u1392_state0_content" class="panel_state_content">

						<!-- 阴影 (动态面板) -->
						<div id="u1393" class="ax_default" data-label="阴影">
							<div id="u1393_state0" class="panel_state" data-label="State1" style="">
								<div id="u1393_state0_content" class="panel_state_content">
								</div>
							</div>
						</div>

						<!-- 背景 (动态面板) -->
						<div id="u1394" class="ax_default" data-label="背景">
							<div id="u1394_state0" class="panel_state" data-label="State1" style="">
								<div id="u1394_state0_content" class="panel_state_content">
								</div>
							</div>
						</div>

						<!-- 菜单 (动态面板) -->
						<div id="u1395" class="ax_default" data-label="菜单">
							<div id="u1395_state0" class="panel_state" data-label="State1" style="">
								<div id="u1395_state0_content" class="panel_state_content">

									<!-- Unnamed (矩形) -->
									<div id="u1396" class="ax_default _默认样式">
										<div id="u1396_div" class=""></div>
										<div id="u1396_text" class="text ">
											<p><span style="text-decoration:none;"><a
														th:href="@{'/home_page/0'}">网站首页</a></span>
											</p>
										</div>
									</div>

									<!-- Unnamed (矩形) -->
									<div id="u1397" class="ax_default _默认样式">
										<div id="u1397_div" class=""></div>
										<div id="u1397_text" class="text ">
											<p><span style="text-decoration:none;"><a
														th:href="@{'/feedback'}">意见反馈</a></span>
											</p>
										</div>
									</div>

									<!-- Unnamed (矩形) -->
									<div id="u1398" class="ax_default _默认样式">
										<div id="u1398_div" class=""></div>
										<div id="u1398_text" class="text ">
											<p><span style="text-decoration:none;"><a
														th:href="@{'/lNotice'}">最新通告</a></span>
											</p>
										</div>
									</div>

									<!-- Unnamed (矩形) -->
									<div id="u1399" class="ax_default _默认样式">
										<div id="u1399_div" class=""></div>
										<div id="u1399_text" class="text ">
											<p><span style="text-decoration:none;"><a
														th:href="@{'/lNews'}">最新消息</a></span></p>
										</div>
									</div>
								</div>
							</div>
						</div>

						<!-- Unnamed (组合) -->
						<div id="u1400" class="ax_default" data-left="44" data-top="0" data-width="45" data-height="50">

							<!-- Unnamed (矩形) -->
							<div id="u1401" class="ax_default _默认样式">
								<div id="u1401_div" class=""></div>
								<div id="u1401_text" class="text " style="display:none; visibility: hidden">
									<p></p>
								</div>
							</div>
						</div>
					</div>
				</div>
			</div>
			<div id="u1391" style="display:none; visibility:hidden;"></div>
		</div>
		<script src="../static/resources/scripts/axure/ios.js"></script>
	</body>
</html>
